﻿<navigation:Page x:Class="RegOnline.PrepodavatelPage" 
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
           xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
           xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
           xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
                    xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"
    xmlns:data="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data"

           mc:Ignorable="d"
           xmlns:navigation="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation"
           d:DesignWidth="800" d:DesignHeight="600"
           Title="PrepodavatelPage Page" Style="{StaticResource PageStyle}">

    <Grid Name="InterfecePrepodGrid1" Style="{StaticResource LayoutRootPageGridStyle}">
        <sdk:TabControl  Name="tabControl1">
            <sdk:TabItem Header="Учебный план" Name="UchPlanTab" FontSize="12">
                <Grid Visibility="Visible" Name="tabitem0">
                    
                    <Grid Visibility="Visible" Name="tabitem1">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition />
                            <ColumnDefinition />
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="56" />
                            <RowDefinition Height="1*"/>
                        </Grid.RowDefinitions>
                        <Grid Margin="20,20,20,0" Name="grid9" VerticalAlignment="Top" Grid.ColumnSpan="2">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="140" />
                                <ColumnDefinition Width="140" />
                                <ColumnDefinition Width="110" />
                                <ColumnDefinition Width="140" />
                                <ColumnDefinition Width="60" />
                                <ColumnDefinition Width="120" />
                            </Grid.ColumnDefinitions>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="26" />
                            </Grid.RowDefinitions>
                            <sdk:Label Content="Год учебного плана:" Grid.Column="0" Margin="3" FontSize="12" HorizontalAlignment="Right"/>
                            <ComboBox ItemsSource="{Binding}" Name="nameGodComboBox"  FontSize="12" Grid.Column="1" SelectionChanged="nameGodComboBox_SelectionChanged" Style="{StaticResource PageComboboxStyle}">
                                <ComboBox.ItemsPanel>
                                    <ItemsPanelTemplate>
                                        <VirtualizingStackPanel />
                                    </ItemsPanelTemplate>
                                </ComboBox.ItemsPanel>
                            </ComboBox>
                            <sdk:Label Content="Тип семестра:" Grid.Column="2" Margin="3" FontSize="12" HorizontalAlignment="Right" />
                            <ComboBox DisplayMemberPath="NameSemType" Grid.Column="3"  ItemsSource="{Binding}" Name="nameSemTypeComboBox" FontSize="12" SelectionChanged="nameSemTypeComboBox_SelectionChanged" Style="{StaticResource PageComboboxStyle}" >
                                <ComboBox.ItemsPanel>
                                    <ItemsPanelTemplate>
                                        <VirtualizingStackPanel />
                                    </ItemsPanelTemplate>
                                </ComboBox.ItemsPanel>
                            </ComboBox>

                            <sdk:Label Content="Группа:" Grid.Column="4" Grid.Row="0" Margin="3"  FontSize="12" HorizontalAlignment="Right"/>
                            <ComboBox DisplayMemberPath="grupName" Grid.Column="5" ItemsSource="{Binding}"  Name="grupNameComboBox1" FontSize="12" SelectionChanged="grupNameComboBox1_SelectionChanged" Style="{StaticResource PageComboboxStyle}" Margin="0,2,2,2">
                                <ComboBox.ItemsPanel>
                                    <ItemsPanelTemplate>
                                        <VirtualizingStackPanel />
                                    </ItemsPanelTemplate>
                                </ComboBox.ItemsPanel>
                            </ComboBox>
                        </Grid>
                        
                       
                        <sdk:DataGrid CanUserSortColumns="False" CanUserResizeColumns="False" IsReadOnly="True" AutoGenerateColumns="False" ItemsSource="{Binding}" Margin="10"
                                      Name="upDataGrid1" RowDetailsVisibilityMode="VisibleWhenSelected"  FontSize="12" MouseLeftButtonUp="upDataGrid1_MouseLeftButtonUp" Grid.Row="1" AreRowDetailsFrozen="False">
                            <sdk:DataGrid.Columns>
                                <sdk:DataGridTextColumn x:Name="disColumn1" Binding="{Binding Path=Dis.DisName}" Header="Дисциплина" Width="Auto" />
                                <sdk:DataGridTextColumn x:Name="vidColumn1" Binding="{Binding Path=Vid.VidWorkName}" Header="Вид работы" Width="Auto" />
                                <data:DataGridTemplateColumn Header="Статус" IsReadOnly="True">
                                    <data:DataGridTemplateColumn.CellTemplate>
                                        <DataTemplate>
                                            <Image Width="20" Height="20" Source="{Binding StatusImageUrl}"   Stretch="Fill"/>
                                        </DataTemplate>
                                    </data:DataGridTemplateColumn.CellTemplate>
                                </data:DataGridTemplateColumn>
                            </sdk:DataGrid.Columns>
                        </sdk:DataGrid>
                        <sdk:GridSplitter Width="4" Background="LightGray" HorizontalAlignment="Left" Margin="-2,0,0,0" VerticalAlignment="Stretch"  Name="gridSplitter1" Grid.Column="1" Grid.Row="1" />


                        <sdk:DataGrid CanUserSortColumns="False" CanUserResizeColumns="False" IsReadOnly="True" AutoGenerateColumns="False" Grid.Row="1"  Grid.Column="1" ItemsSource="{Binding }" Name="reqsWorkDTODataGrid1" RowDetailsVisibilityMode="VisibleWhenSelected" Margin="10,33,10,10" FontSize="12" SelectionChanged="reqsWorkDTODataGrid1_SelectionChanged">
                            <sdk:DataGrid.Columns>
                                <sdk:DataGridTextColumn x:Name="ExpDocColumn" Binding="{Binding Path=LR.RR.nameReq}" Header="Название требования" Width="Auto" />
                                <sdk:DataGridTextColumn x:Name="ReqColumn" Binding="{Binding Path=LR.expdoc}" Header="Расширение документа" Width="Auto" />
                                <data:DataGridTemplateColumn Width="80">
                                    <data:DataGridTemplateColumn.CellTemplate>
                                        <DataTemplate>
                                            <Button x:Name="btnDelete" Content="Удалить" Foreground="DarkBlue" Click="btnDelete_Click" Width="75">

                                            </Button>
                                        </DataTemplate>
                                    </data:DataGridTemplateColumn.CellTemplate>
                                </data:DataGridTemplateColumn>
                            </sdk:DataGrid.Columns>
                        </sdk:DataGrid>
                        <sdk:Label Grid.Column="1" HorizontalAlignment="Center" Grid.Row="1" Height="34"  Margin="64,211,50,220" Name="label3" VerticalAlignment="Center" Width="260"  Visibility="Collapsed" Content="Требований по работе нет" />
                        <Rectangle Grid.Column="1" Grid.Row="1" Height="52" HorizontalAlignment="Center" Margin="64,201,50,212" Name="rectangle3" Stroke="Black" StrokeThickness="1" VerticalAlignment="Center" Width="260" Visibility="Collapsed"/>
                        <Button Content="Добавить требование" Grid.Row="1" Grid.Column="1" HorizontalAlignment="Left" Margin="10,5,0,0" Name="button5" VerticalAlignment="Top" Width="160" FontSize="12" Click="button5_Click" Style="{StaticResource PageButtonStyle}" />
                        
                       
                       
                    </Grid>
                
                </Grid>

            </sdk:TabItem>

            <sdk:TabItem Header="Список зарегистрированных работ" Name="ZaregWork" FontSize="12">
                <Grid>
                    <Grid Margin="10" VerticalAlignment="Top" HorizontalAlignment="Stretch">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="135" />
                            <ColumnDefinition Width="2*" />
                            <ColumnDefinition Width="100" />
                            <ColumnDefinition Width="2*" />
                            <ColumnDefinition Width="100" />
                            <ColumnDefinition Width="2*" />
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="30" />
                            <RowDefinition Height="30" />
                            <RowDefinition Height="30" />
                        </Grid.RowDefinitions>
                        <sdk:Label Content="Год учебного плана:" Grid.Column="0" Grid.Row="0" HorizontalAlignment="Left" Margin="3" VerticalAlignment="Center" FontSize="12" />
                        <ComboBox  Grid.Column="1" ItemsSource="{Binding}" Margin="3" Name="nameGodComboBox1"  FontSize="12" SelectionChanged="nameGodComboBox1_SelectionChanged" Style="{StaticResource PageComboboxStyle}">
                            <ComboBox.ItemsPanel>
                                <ItemsPanelTemplate>
                                    <VirtualizingStackPanel />
                                </ItemsPanelTemplate>
                            </ComboBox.ItemsPanel>
                        </ComboBox>
                        
                        <sdk:Label Content="Тип семестра:" Grid.Column="2" Grid.Row="0" HorizontalAlignment="Right" Margin="3" VerticalAlignment="Center" FontSize="12" />
                        <ComboBox DisplayMemberPath="NameSemType" Grid.Column="3"  ItemsSource="{Binding}" Margin="3" Name="nameSemTypeComboBox1"  FontSize="12" SelectionChanged="nameSemTypeComboBox1_SelectionChanged" Style="{StaticResource PageComboboxStyle}">
                            <ComboBox.ItemsPanel>
                                <ItemsPanelTemplate>
                                    <VirtualizingStackPanel />
                                </ItemsPanelTemplate>
                            </ComboBox.ItemsPanel>
                        </ComboBox>

                        <sdk:Label Content="Группа:" Grid.Column="4" HorizontalAlignment="Right" Margin="3,3,0,3" VerticalAlignment="Center" FontSize="12" Width="97" />
                        <ComboBox DisplayMemberPath="grupName" Grid.Column="5" ItemsSource="{Binding}" Margin="3" Name="grupNameComboBox2" FontSize="12" SelectionChanged="grupNameComboBox2_SelectionChanged" Style="{StaticResource PageComboboxStyle}">
                            <ComboBox.ItemsPanel>
                                <ItemsPanelTemplate>
                                    <VirtualizingStackPanel />
                                </ItemsPanelTemplate>
                            </ComboBox.ItemsPanel>
                        </ComboBox>

                        <sdk:Label Content="Дисциплина:" Grid.Row="1" HorizontalAlignment="Left" Margin="3,3,0,3" VerticalAlignment="Center" FontSize="12" Width="129" />
                        <ComboBox DisplayMemberPath="DisName" Grid.Column="1" Grid.Row="1" Grid.ColumnSpan="2" ItemsSource="{Binding}" Margin="3" Name="disNameComboBox" SelectionChanged="disNameComboBox_SelectionChanged" MouseRightButtonUp="disNameComboBox_MouseRightButtonUp" FontSize="12" Style="{StaticResource PageComboboxStyle}">
                            <ComboBox.ItemsPanel>
                                <ItemsPanelTemplate>
                                    <VirtualizingStackPanel />
                                </ItemsPanelTemplate>
                            </ComboBox.ItemsPanel>
                        </ComboBox>

                        <sdk:Label  Content="Вид работы:" Grid.Column="3" Grid.Row="1" HorizontalAlignment="Right" Margin="3,3,0,3" VerticalAlignment="Center" FontSize="12" Width="125" />
                        <ComboBox DisplayMemberPath="VidWorkName" Grid.Column="4" Grid.Row="1" Grid.ColumnSpan="2"  ItemsSource="{Binding}" Margin="3" Name="vidWorkNameComboBox" FontSize="12" SelectionChanged="vidWorkNameComboBox_SelectionChanged" Style="{StaticResource PageComboboxStyle}">
                            <ComboBox.ItemsPanel>
                                <ItemsPanelTemplate>
                                    <VirtualizingStackPanel />
                                </ItemsPanelTemplate>
                            </ComboBox.ItemsPanel>
                        </ComboBox>

                        <sdk:Label Content="Введите период:   с" Grid.Row="2" HorizontalAlignment="Left" Margin="3,3,0,3" VerticalAlignment="Center" FontSize="12" Width="132" />
                        <sdk:DatePicker Grid.Column="1" Grid.Row="2"  Margin="3" Name="regDateDatePicker" SelectedDate="{Binding Path=RegDate, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" FontSize="12" />

                        <sdk:Label Content="по" Grid.Column="2" Grid.Row="2" HorizontalAlignment="Center" Margin="3,3,0,3" VerticalAlignment="Center" FontSize="12" Width="94" />
                        <sdk:DatePicker Grid.Column="3" Grid.Row="2" Margin="3" Name="regDateDatePicker1" SelectedDate="{Binding Path=RegDate, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}" SelectedDateChanged="regDateDatePicker1_SelectedDateChanged" FontSize="12" />

                        <Button Content="Печать" Height="23" Grid.Column="5" Grid.Row="2" HorizontalAlignment="Center" Name="button9" VerticalAlignment="Center" Width="100" FontSize="12" IsEnabled="true" Click="button9_Click" Style="{StaticResource PageButtonStyle}" />
                        <Button Content="Отобразить" Height="23" Grid.Column="4" Grid.Row="2" HorizontalAlignment="Center" Name="button10" VerticalAlignment="Center" Width="100" FontSize="12" IsEnabled="true" Click="button10_Click_1" Style="{StaticResource PageButtonStyle}" Grid.ColumnSpan="2" Margin="3,4,128,4"></Button>
                    </Grid>

                    <sdk:DataGrid CanUserSortColumns="False" CanUserResizeColumns="False" IsReadOnly="True" AutoGenerateColumns="False"  ItemsSource="{Binding }" Margin="20,110,20,20" Name="worksDTODataGrid1" RowDetailsVisibilityMode="VisibleWhenSelected" SelectionChanged="worksDTODataGrid1_SelectionChanged" >
                        <sdk:DataGrid.Columns> 
                            <sdk:DataGridTextColumn x:Name="ZachColumn1" Binding="{Binding Path=St.zach.nZach}" Header="№ зачетки" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="surnameColumn1" Binding="{Binding Path=St.person.LastName}" Header="Фамилия" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="nameColumn1" Binding="{Binding Path=St.person.FirstName}" Header="Имя" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="ochColumn1" Binding="{Binding Path=St.person.Patronymic}" Header="Отчество" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="themeColumn1" Binding="{Binding Path=theme}" Header="Тема" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="optionsColumn1" Binding="{Binding Path=options}" Header="Вариант" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="regDateColumn1" Binding="{Binding Path=RegDate, StringFormat='dd.MM.yyyy'}" Header="Дата" Width="Auto" />
                            <sdk:DataGridTextColumn x:Name="regNumColumn1" Binding="{Binding Path=RegNum}"  Header="Регистрационный №" Width="Auto" />

                        </sdk:DataGrid.Columns>
                    </sdk:DataGrid>
                    <Rectangle Height="50" HorizontalAlignment="Center"  Name="rectangle2" Stroke="Black" StrokeThickness="1" VerticalAlignment="center" Width="334" Margin="207,280,207,190" Visibility="Collapsed"/>
                    <sdk:Label Content="Зарегистрированных работ в этот период нет" Height="50" HorizontalAlignment="Center" Margin="207,280,207,191" Name="label2" VerticalAlignment="center" Visibility="Collapsed" Width="334" />
                </Grid>
            </sdk:TabItem>
        </sdk:TabControl>
    </Grid>

</navigation:Page>
